﻿<?php 
//session
header("Cache-control:private");

//timezone 
date_default_timezone_set('PRC');
ini_set('display_errors', 'on');
ini_set('max_execution_time', '1800'); 
//error_reporting
error_reporting(E_ALL & ~E_NOTICE & ~E_WARNING & ~E_STRICT & ~E_DEPRECATED);
session_start(3600*24);


/*$dsn_user = array( 
'phptype' => 'mysql', 
'user' => 'fumeng_test', 
'pwd' => 'xiaohu2470',
'port' => '3306', 
'host' => '127.0.0.1', 
'db_name' => 'fumeng_test', 
'db_charset' => 'utf8', 
);*/

//db setting

$dsn_user = array( 
'phptype' => 'mysql', 
'user' => 'fumeng_test',
'pwd' => 'xiaohu2470',
'port' => '3306', 
'host' => '127.0.0.1', 
'db_name' => 'fumeng_test',
'db_charset' => 'utf8', 
);

define('SCHEME',empty($_SERVER['REQUEST_SCHEME'])?'http':strtolower($_SERVER['REQUEST_SCHEME']));

define('HOST',$_SERVER['HTTP_HOST']);
//site url
define('SITEURL',SCHEME.'://'.HOST.'/');

define('SITE_URL',SCHEME.'://'.HOST.'/fumeng_test/');


define('STATICDIR',SITEURL.'fumeng_test/static/');

define('IN_APP','fumeng_test');

define('ROOTDIR', realpath(dirname(__FILE__))."/../");

define('TEMPLATE_DIR', ROOTDIR . 'template/');
// Temlate cache
define('TEMPLATE_DATA_DIR', ROOTDIR . 'cache');

define('IMG_DIR', ROOTDIR . 'static/upload/');

define('UPLOAD_IMG_URL', STATICDIR . 'upload/');

//日志配置
$_logconf = array('mode' => 0644, 'timeFormat' => '%Y-%m-%d %X');
$_logfile = array(
		'db'=>ROOTDIR.'log/db.log',
		'debug'=>ROOTDIR.'log/debug.log'
);
$_loglevel = 7;  // 0:EMERG,1:ALERT,2:CRIT,3:ERR,4:WARNING,5:NOTIC,6:INFO,7:DEBUG


require_once (ROOTDIR."source/service/Logger.class.php");

require_once (ROOTDIR."source/service/Template.class.php");

require_once(ROOTDIR.'source/function/function.php');


require_once (ROOTDIR."source/service/class/class.user.php");

require_once (ROOTDIR."source/service/class/class.admin.php");

require_once(ROOTDIR.'source/service/class/class.chanpin.php');

require_once(ROOTDIR.'source/service/class/class.oplog.php');

require_once(ROOTDIR.'source/service/class/class.fanli.php');

require_once(ROOTDIR.'source/service/class/class.tixian.php');

require_once(ROOTDIR.'source/service/class/class.gonggao.php');

require_once(ROOTDIR.'source/service/class/class.tongji.php');

require_once(ROOTDIR.'source/service/class/class.account_number.php');


$sysMenuList['C']['name'] = "产品中心";
$sysMenuList['C']['list']['C100001']['name'] = '产品列表';
$sysMenuList['C']['list']['C100001']['url'] = 'chanpinM';
$sysMenuList['C']['list']['C100002']['name'] = '产品统计';
$sysMenuList['C']['list']['C100002']['url'] = 'chanpinC';


$sysMenuList['Y']['name'] = "用户中心";
$sysMenuList['Y']['list']['Y100001']['name'] = '用户列表';
$sysMenuList['Y']['list']['Y100001']['url'] = 'userM';
$sysMenuList['Y']['list']['Y100002']['name'] = '返利列表';
$sysMenuList['Y']['list']['Y100002']['url'] = 'fanliM';
$sysMenuList['Y']['list']['Y100003']['name'] = '提现列表';
$sysMenuList['Y']['list']['Y100003']['url'] = 'tixianM';

$sysMenuList['G']['name'] = "公告管理";
$sysMenuList['G']['list']['G100001']['name'] = '公告列表';
$sysMenuList['G']['list']['G100001']['url'] = 'gonggaoM';


$sysMenuList['Z']['name'] = "帐号管理";
$sysMenuList['Z']['list']['Z100001']['name'] = '帐号列表';
$sysMenuList['Z']['list']['Z100001']['url'] = 'adminM';


$backList['1'] = '工商银行';
$backList['2'] = '中国银行';






